var path = require('path');
const webpack = require('webpack');
module.exports = {
    entry: "./js/src/xUI.js",
    output: {
        path: __dirname,
        libraryTarget: 'umd',
        library: "xUI",
        umdNamedDefine: true,
        filename: "./js/lib/xUI.min.js"
    },
    module: {
        rules: [
            {
                test: /\.js$/,
                exclude: /(node_modules|bower_components)/,
                use: {
                    loader: 'babel-loader',
                    options: {
                        presets: ['@babel/preset-env'],
                        plugins: [
                            ['@babel/plugin-proposal-decorators', {"legacy": true}],
                            ['@babel/plugin-proposal-class-properties', {"loose": false}]]
                    }
                }
            }
        ]
    }
}


